<?xml version="1.0" encoding="ISO-8859-15"?>
<!-- DOC - TP XSLT -->
<!--cuisine2nutrition.xsl -->
<xsl:stylesheet version="1.0" 
	xmlns:xsl="http://www.w3.org/1999/XSL/Transform" >
	<xsl:output method="xml" version="1.0" indent="yes"	encoding="UTF-8" 
		doctype-system="nutrition.dtd"/>
	
<!-- Produire du XML -->
	<xsl:template match="recettes">
		<nutrition>
			<xsl:for-each select="recette">
				<plat>
					<xsl:attribute name="nom">
						<xsl:value-of select="nom"/>
					</xsl:attribute>
					<xsl:attribute name="alcool">
						<xsl:value-of select="nutrition/@alcool"/>
					</xsl:attribute>
					<xsl:attribute name="proteines">
						<xsl:value-of select="nutrition/@proteines"/>
					</xsl:attribute>
					<xsl:attribute name="gras">
						<xsl:value-of select="nutrition/@gras"/>
					</xsl:attribute>
					<xsl:attribute name="calories">
						<xsl:value-of select="nutrition/@calories"/>
					</xsl:attribute>
					<xsl:attribute name="glucides">
						<xsl:value-of select="nutrition/@glucides"/>
					</xsl:attribute>
				</plat>
			</xsl:for-each>
		</nutrition>
	</xsl:template>
</xsl:stylesheet>
